<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<header>
	<div class="header0">
		<div class="header1">
			<div class="logo"><a href="#"><img src="${pageContext.request.contextPath}/assets/images/logo2.png"></a></div>
            <c:choose>
            	<c:when test="${sessionScope.username != null && sessionScope.username != ''}">
            		<div style="float: right;display: block">
            			<div id="headrightText" style="color:#fff;text-align:center;width:655px;height:64px;line-height:52px;margin-right:20px;float:left;">
            			</div>
						<div class="menuitem" style="padding-top:11px;padding-right:30px;text-align:center; float:left">
	            			<a href="${pageContext.request.contextPath}/login/logout">
	            				<i class="icono-eye" style=""></i>
	            			</a>
	            			<div class="submenu">
					            <div value="default">默认</div>
					            <div value="blue">蓝色</div>
					            <div value="green">绿色</div>
					            <div value="blueGreen">蓝绿</div>
					            <div value="orange">橙色</div>
					            <div value="purple">紫色</div>
					            <div value="purpleRed">紫红</div>
					            <div value="dark">深黑</div>
					            <div value="redBlack">红黑</div>
					            <div value="warm">暖色</div>
					            <div value="gray">灰色</div>
					            <div value="yellow">黄色</div>
					            <div value="redPurple">红紫</div>
					        </div>
            			</div>
            			<div style="padding-top:11px;padding-right:12px;text-align:center; float:left">
	            			<a href="${pageContext.request.contextPath}/login/logout">
	            				<i class="icono-power" style=""></i>
	            			</a>
            			</div>
            		</div>
            	</c:when>
            </c:choose>
        </div>
	</div>
	<script type="text/javascript">
		function getNowFormatDate() {
		    var date = new Date();
		    var seperator1 = "/";
		    var seperator2 = ":";
		    var month = date.getMonth() + 1;
		    var strDate = date.getDate();
		    if (month >= 1 && month <= 9) {
		        month = "0" + month;
		    }
		    if (strDate >= 0 && strDate <= 9) {
		        strDate = "0" + strDate;
		    }
		    var week;
		    switch (date.getDay()){
		    case 1: week="星期一"; break;
		    case 2: week="星期二"; break;
		    case 3: week="星期三"; break;
		    case 4: week="星期四"; break;
		    case 5: week="星期五"; break;
		    case 6: week="星期六"; break;
		    default: week="星期天";
		    }
		    var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate
		            + "&nbsp&nbsp&nbsp" + week + "&nbsp&nbsp&nbsp" + date.getHours() + seperator2 + date.getMinutes()
		            + seperator2 + date.getSeconds() + "&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp"
		    		+ "${sessionScope.username}" + ",你好！"
		    return currentdate;
		}
		<!--
		seajs.use('jquery', function($) {
			var currentdate = getNowFormatDate();
			$("#headrightText").html(currentdate);
			setInterval("$('#headrightText').html(getNowFormatDate())",1000);
		});
	//-->
	</script>
</header>
